/**
 * 
 */
package com.eclipse.org.snms.reminder;

import java.util.Calendar;

import com.eclipse.org.snms.TaskComposite;
import com.eclipse.org.snms.serializer.loadStickyNotes.SerializerConcreteSubject;
import com.eclipse.org.snms.summary.SummarySubjectConcrete;

/**
 * @author dimitri.tiago
 */
public class StartUp 
{
	public static void main(String[] args) 
	{
		// instantiate summary and serializer objects
		SummarySubjectConcrete summary = new SummarySubjectConcrete();
		SerializerConcreteSubject serializer = new SerializerConcreteSubject();
		
		// instantiate reminder object
		ReminderSubjectConcrete reminder = new ReminderSubjectConcrete(summary, serializer);
				
		// check sticky note deadlines
		while (true)
		{
			// if deadline expired 
			reminder.checkDeadlines();
			
			try
			{
				// sleep 60 seconds
				Thread.sleep(60000);
			}
			catch(InterruptedException e)
			{
				// print stack trace
				e.printStackTrace();
			}
			
			//reminder.printOutlist();
			System.out.println("------------------------------");
		}
	}
}
